package com.kh.first.pojo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.kh.first.utils.LongJsonSerializer;
import com.kh.first.utils.QuotaSerializer;
import com.kh.first.utils.TN;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.format.annotation.NumberFormat;

import java.math.BigDecimal;
import java.util.Date;

@Data
@TN("production_report")
public class ProductReportPojo {
    @JsonSerialize(using = LongJsonSerializer.class)
    private Long id;
    private String dept;
    private String productionLine;//线别
    private String packageNumber;//件号

    private String createUserName;//由员工创建
    private String createUserWorkNo;
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;
    private Integer schedulingNo;//班次
    private Integer schedulingCategory;//班别
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date startWorkTime;//起
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date endWorkTime;//止
    private BigDecimal extraHours;//加班

    @JsonSerialize(using = QuotaSerializer.class)
    private String quota;//7个时间段的定额,接受的时候是字符串，返回的时候是数组,整数个数

    //    毛坯个数
    private Integer simplyProductNo;//毛坯总个数
    //成品个数
    private Integer completeProductNo;
    //工废
    private Integer processLostNo;
    //料废
    private Integer materialLostNo;
    //默认你选的是谁来确定的，方便员工一直填写
    private String defaultChooseWorkNo;//班长的工号
    /**
     * -------------------------------------------------------------------------------------------------------------
     */
    // 料废
//    private Integer no1WithStep1MaterialLostNo;
//    //工废
//    private Integer no1WithStep1ProcessLostNo;
//    private String no1WithStep1Reason;
//
//    // 成品-------------
//    @NumberFormat
//    private Integer no1WithStep1;
//    private Integer no1WithStep2;
//    // 成品-------------
//    private Integer no2ProcessLostNo;
//    private Integer no2MaterialLostNo;
//    private String no2Reason;
//    private Integer no2;
//    private Integer no3WithStep1;
//    private Integer no3WithStep2;
//    private Integer no4WithStep1;
//    private Integer no4WithStep2;
//    private Integer no1WithStep2MaterialLostNo;
//    private Integer no1WithStep2ProcessLostNo;
//    private String no1WithStep2Reason;
//    private Integer no3WithStep1MaterialLostNo;
//    private Integer no3WithStep1ProcessLostNo;
//    private String no3WithStep1Reason;
//    private Integer no3WithStep2MaterialLostNo;
//    private Integer no3WithStep2ProcessLostNo;
//    private String no3WithStep2Reason;
//    private Integer no4WithStep1MaterialLostNo;
//    private Integer no4WithStep1ProcessLostNo;
//    private String no4WithStep1Reason;
//    private Integer no4WithStep2MaterialLostNo;
//    private Integer no4WithStep2ProcessLostNo;
//    private String no4WithStep2Reason;
//    private Integer status;
//    private String ioUser;
//    //---确认人
//    private String confirmUserId;
//    private String confirmUserName;
//    private String confirmUserSignPath;
}
